﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication3
{
    class Program
    {
        static void Main(string[] args)
        {
            string answer = "Y";
                List<Student> StudentList = new List<Student>();
                do
                {
                Student oneMoreStudent = new Student();
                oneMoreStudent.EnterCredentials();
                StudentList.Add(oneMoreStudent);
                Console.Clear();
                Console.WriteLine("хотите добавить ещё одного студента?");
                answer = Console.ReadLine().ToUpper();
                Console.Clear();
                while (answer != "Y" && answer != "N") 
                    {
                    Console.WriteLine("выберите Y или N");
                    answer = Console.ReadLine().ToUpper();
                    }
                Console.Clear();
                }
            while (answer != "N");
            foreach (var oneMoreStudent in StudentList)
            {
                if (oneMoreStudent.AverageMarkCount() >= 67) oneMoreStudent.PrintStudentInfo();
            }
            
            

        }
    }
}
